package a.g;

import a.f.l.e;
import a.f.l.g;
import a.f.l.k;
import a.f.l.l;
import a.f.rc;
import a.h.cc;
import a.h.dc;
import a.h.nc;
import a.h.z;

public class w
  extends h
{
  private static final String q = "ORTHOGONAL_EDGE_ROUTER";
  private static final String r = "SCOPE";
  private static final String s = "ALL_EDGES";
  private static final String t = "SELECTED_EDGES";
  private static final String u = "AT_SELECTED_NODES";
  private static final String v = "MINIMUM_DISTANCE_TO_EDGE";
  private static final String w = "USE_CUSTOM_MINIMUM_DISTANCE_TO_NODE";
  private static final String x = "CUSTOM_MINIMUM_DISTANCE_TO_NODE";
  private static final String y = "SPACE_DRIVEN_VS_CENTER_DRIVEN_SEARCH";
  private static final String z = "LOCAL_CROSSING_MINIMIZATION";
  private static final String A = "GRID_SPACING";
  private static final String B = "ROUTE_ON_GRID";
  private static final String C = "CROSSING_COST";
  private static final String D = "REROUTING_ENABLED";
  private static final String E = "MONOTONIC_NONE";
  private static final String F = "MONOTONIC_VERTICAL";
  private static final String G = "MONOTONIC_HORIZONTAL";
  private static final String H = "MONOTONIC_BOTH";
  private static final String I = "MONOTONIC_RESTRICTION";
  private static final String J = "ENFORCE_MONOTONIC_RESTRICTIONS";
  private static final String K = "CONSIDER_NODE_LABELS";
  private static final String L = "LAYOUT_OPTIONS";
  private static final String M = "CROSSING_MINIMIZATION";
  private static final Object[] N = { "MONOTONIC_NONE", "MONOTONIC_HORIZONTAL", "MONOTONIC_VERTICAL", "MONOTONIC_BOTH" };
  private g O;
  public static boolean P;
  
  public w()
  {
    super("ORTHOGONAL_EDGE_ROUTER", "yFiles Layout Team", "Routes edges orthogonally.");
    d(true);
  }
  
  protected void m()
  {
    z();
  }
  
  protected void n()
  {
    a(new e(new a.f.l.f(new l(new k(this.O)))));
  }
  
  protected void o()
  {
    this.O = null;
  }
  
  protected dc j()
  {
    dc localdc = new dc(a());
    a(localdc, null);
    return localdc;
  }
  
  void a(dc paramdc, rc paramrc)
  {
    int i = f.p;
    boolean bool = f.o;
    paramdc.g();
    if (i == 0) {
      if (paramrc == null) {
        paramrc = new g();
      }
    }
    g localg = (g)paramrc;
    cc localcc = new cc();
    localcc.a("OptionGroup.title", "LAYOUT_OPTIONS");
    String[] arrayOfString = { "ALL_EDGES", "SELECTED_EDGES", "AT_SELECTED_NODES" };
    if (i == 0) {
      if (localg.G() == 0)
      {
        localcc.a(paramdc.a("SCOPE", arrayOfString, 0));
        if (i != 0) {
          break label233;
        }
        if (!bool) {
          break label165;
        }
      }
    }
    if (i == 0)
    {
      if (localg.G() == 4)
      {
        localcc.a(paramdc.a("SCOPE", arrayOfString, 1));
        if (i != 0) {
          break label233;
        }
      }
    }
    else {
      if (!bool) {
        break label165;
      }
    }
    localcc.a(paramdc.a("SCOPE", arrayOfString, 2));
    label165:
    localcc.a(paramdc.a("MONOTONIC_RESTRICTION", N, 0));
    localcc.a(paramdc.a("ENFORCE_MONOTONIC_RESTRICTIONS", localg.f()));
    localcc.a(paramdc.a("MINIMUM_DISTANCE_TO_EDGE", localg.K()));
    paramdc.k("MINIMUM_DISTANCE_TO_EDGE").a(nc.y, new Integer(4));
    label233:
    if (i == 0) {}
    localcc.a(paramdc.a("USE_CUSTOM_MINIMUM_DISTANCE_TO_NODE", !localg.L()));
    localcc.a(paramdc.a("CUSTOM_MINIMUM_DISTANCE_TO_NODE", localg.M()));
    paramdc.k("CUSTOM_MINIMUM_DISTANCE_TO_NODE").a(nc.y, new Integer(2));
    localcc.a(paramdc.a("ROUTE_ON_GRID", localg.H()));
    localcc.a(paramdc.a("GRID_SPACING", localg.J()));
    paramdc.k("GRID_SPACING").a(nc.y, new Integer(2));
    localcc.a(paramdc.a("SPACE_DRIVEN_VS_CENTER_DRIVEN_SEARCH", localg.P(), 0.0D, 1.0D));
    localcc.a(paramdc.a("CONSIDER_NODE_LABELS", localg.d()));
    localcc = new cc();
    localcc.a("OptionGroup.title", "CROSSING_MINIMIZATION");
    localcc.a(paramdc.a("LOCAL_CROSSING_MINIMIZATION", localg.O()));
    localcc.a(paramdc.a("CROSSING_COST", localg.u()));
    localcc.a(paramdc.a("REROUTING_ENABLED", localg.v()));
    z localz = new z(paramdc);
    localz.a("ROUTE_ON_GRID", Boolean.TRUE, "GRID_SPACING");
    localz.a("USE_CUSTOM_MINIMUM_DISTANCE_TO_NODE", Boolean.TRUE, "CUSTOM_MINIMUM_DISTANCE_TO_NODE");
  }
  
  public void b(rc paramrc)
  {
    dc localdc = i();
    a(localdc, paramrc);
  }
  
  public void c(rc paramrc)
  {
    int i = f.p;
    boolean bool = f.o;
    if ((i != 0) || ((paramrc instanceof g)))
    {
      g localg = (g)paramrc;
      dc localdc = i();
      String str = localdc.h("SCOPE");
      if (i == 0) {
        if (str.equals("AT_SELECTED_NODES"))
        {
          localg.b((byte)4);
          if (i != 0) {
            break label115;
          }
          if (!bool) {
            break label105;
          }
        }
      }
      if (i == 0)
      {
        if (str.equals("SELECTED_EDGES"))
        {
          localg.b((byte)2);
          if (i != 0) {
            break label115;
          }
        }
      }
      else {
        if (!bool) {
          break label105;
        }
      }
      localg.b((byte)0);
      label105:
      localg.c(localdc.e("MINIMUM_DISTANCE_TO_EDGE"));
      label115:
      if (i == 0) {}
      localg.e(!localdc.g("USE_CUSTOM_MINIMUM_DISTANCE_TO_NODE"));
      localg.d(localdc.e("CUSTOM_MINIMUM_DISTANCE_TO_NODE"));
      localg.d(localdc.g("ROUTE_ON_GRID"));
      localg.b(localdc.e("GRID_SPACING"));
      localg.c(localdc.f("SPACE_DRIVEN_VS_CENTER_DRIVEN_SEARCH"));
      localg.f(localdc.g("LOCAL_CROSSING_MINIMIZATION"));
      if (i == 0) {
        if ("MONOTONIC_BOTH".equals(localdc.h("MONOTONIC_RESTRICTION")))
        {
          localg.a((byte)3);
          if (i != 0) {
            break label337;
          }
          if (!bool) {
            break label295;
          }
        }
      }
      if (i == 0) {
        if ("MONOTONIC_HORIZONTAL".equals(localdc.h("MONOTONIC_RESTRICTION")))
        {
          localg.a((byte)2);
          if (i != 0) {
            break label337;
          }
          if (!bool) {
            break label295;
          }
        }
      }
      if (i == 0)
      {
        if ("MONOTONIC_VERTICAL".equals(localdc.h("MONOTONIC_RESTRICTION"))) {
          localg.a((byte)1);
        }
      }
      else
      {
        if (i != 0) {
          break label337;
        }
        if (!bool) {
          break label295;
        }
      }
      localg.a((byte)0);
      label295:
      localg.b(localdc.g("ENFORCE_MONOTONIC_RESTRICTIONS"));
      localg.a(localdc.g("CONSIDER_NODE_LABELS"));
      localg.b(localdc.f("CROSSING_COST"));
      localg.c(localdc.g("REROUTING_ENABLED"));
      label337:
      if (!bool) {}
    }
    else
    {
      throw new IllegalArgumentException("argument must be of type y.layout.router.OrthogonalEdgeRouter");
    }
  }
  
  private void z()
  {
    if (f.p == 0)
    {
      if (this.O != null) {
        return;
      }
      this.O = new g();
    }
    c(this.O);
  }
}



/* Location:           E:\idea\

 * Qualified Name:     a.g.w

 * JD-Core Version:    0.7.0.1

 */